import 'package:flutter/widgets.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';

Widget sizeUtilInit(WidgetBuilder builder) {
  return ScreenUtilInit(
    designSize: const Size(750, 1334),
    builder: builder,
  );
}

typedef WidgetSizeBuilder = Widget Function();

double getHeight(double size) {
  return ScreenUtil().setHeight(size);
}

double getWidth(double size) {
  return ScreenUtil().setWidth(size);
}

double getSp(double size) {
  return ScreenUtil().setSp(size);
}

double getStatusBarHeight(double size) {
  return ScreenUtil().statusBarHeight;
}

double getWindWidth() {
  return ScreenUtil().screenWidth;
}
